<script src="node_modules/socket.io/node_modules/socket.io-client/dist/socket.io.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js" type="text/javascript"></script>

<script type="text/javascript">
    var sock = io.connect('http://localhost');

    sock.on('connect', function () {
        console.log('connect');
    });

    sock.on('disconnect', function () {
        console.log('disconnect');
    });

    sock.on('rst', function (data) {
        console.log(data);
    });
   
</script>